<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2021/11/12
 * Time: 10:20
 */
namespace app\controller;
use app\BaseController;
use app\common\model\mysql\User;
use think\facade\Db;//门面模式获取的DB

class Date extends BaseController{
    public function index()
    {
//        $info =Db::table('user')->order('id','desc')->page(1,2)->select();
        //通过容器获取
//        $info = app('db')->table('user')->where('id',1)->find();
        $info = User::select();
        dump($info);
    }
}